package com.itheima.bos.service.take_delivery;

import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.PathParam;
import javax.ws.rs.Produces;
import javax.ws.rs.QueryParam;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import com.itheima.bos.domain.take_delivery.PageBean;
import com.itheima.bos.domain.take_delivery.Promotion;

public interface IPromotionService {

	public void save(Promotion model);

	public Page<Promotion> findAll(Pageable pageable);
	
	//webservice提供的分页查询接口
	@Path("/queryPage")
	@GET
	@Produces({"application/xml","application/json"})
	public PageBean<Promotion> findPageData(@QueryParam("page") int page,@QueryParam("rows") int rows); 
	
	
	//webservice提供促销详情的接口
	@Path("/promotiom_detail/{id}")
	@GET
	@Produces({"application/xml","application/json"})
	public Promotion findById(@PathParam("id") Integer id);
}
